//
//  HYsearchGameCell.m
//  HaiYue
//
//  Created by skyline on 2018/6/4.
//  Copyright © 2018年 skyline. All rights reserved.
//

#import "HYSearchGameCell.h"
@interface  HYSearchGameCell()
@property (nonatomic, strong) HYImageView *IMG;
@property (nonatomic, strong) HYLabel *titleLBL;
@end
@implementation HYSearchGameCell
- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self)
    {
        self.titleLBL.hidden = NO;
    }
    return self;
}

- (HYImageView *)IMG
{
    if (!_IMG)
    {
       _IMG = [[HYImageView alloc] initWithCornerRadius:GAP];
        _IMG.image = [UIImage imageNamed:@"1"];
        [self addSubview:_IMG];
        [_IMG mas_makeConstraints:^(MASConstraintMaker *make) {
            make.left.equalTo(self).with.offset(GAP);
            make.centerY.equalTo(self);
            make.size.mas_offset(CGSizeMake(HYOnlineCellIMG_Width, HYOnlineCellIMG_Width));
        }];
    }
    return _IMG;
}

- (HYLabel *)titleLBL
{
    if (!_titleLBL)
    {
       _titleLBL = [[HYLabel alloc] initWithText:@"乱世online" textColor:TEXT_BLACK_COLOR textFont:[UIFont systemFontOfSize:ContentFont weight:UIFontWeightLight]];
        [self addSubview:_titleLBL];
        [_titleLBL mas_makeConstraints:^(MASConstraintMaker *make) {
            make.left.equalTo(self.IMG.mas_right).with.offset(GAP / 2.0);
            make.centerY.equalTo(self);
        }];
    }
    return _titleLBL;
}
@end
